﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/SiteNew.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Đơn hàng đã mua
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <div id="page-heading"><h1>Đơn hàng đã mua</h1></div>
  
    <script>
        $(function () {
            $("button, input:submit,input:text,.details").button();

        });
	</script>

	<table border="0" width="100%" cellpadding="0" cellspacing="0" id="content-table">
	<tr>
		<th rowspan="3" class="sized"><img src="/Assets/Images/shared/side_shadowleft.jpg" width="20" height="300" alt="" /></th>
		<th class="topleft"></th>
		<td id="tbl-border-top">&nbsp;</td>
		<th class="topright"></th>
		<th rowspan="3" class="sized"><img src="/Assets/Images/shared/side_shadowright.jpg" width="20" height="300" alt="" /></th>
	</tr>
	<tr>
		<td id="tbl-border-left"></td>
		<td>
		<!--  start content-table-inner ...................................................................... START -->
		<div id="content-table-inner">
		
			<!--  start table-content  -->
			<div id="table-content">
			
				                <style type="text/css">
                    #orderTable
                    {
                        border:1px solid #0073EA;
                        }
                    #orderTable th
                    {
                        height:50px;
                        text-align:center;
                        vertical-align:middle;
                        }
                        #orderTable td
                    {
                        text-align:center;
                        vertical-align:middle;
                        padding:10px;
                        }
                </style>
                <table id="orderTable"  border="1px solid #0073EA" cellpadding="1" cellspacing="1"   width="100%">
		           <tr class="ui-state-hover">
					<th  valign="top" style="text-align: center;"><a href="">Nhà xe</a>	</th>
					<th  valign="top" style="text-align: center;"><a href="">Ghế mua</a></th>
					<th  valign="top" style="text-align: center;"><a href="">Giá vé</a> </th>
					<th  valign="top" style="text-align: center;"><a href="">Số lượng</a></th>
					<th  valign="top" style="text-align: center;"><a href="">Tổng tiền</a></th>
					<th  valign="top" style="text-align: center;"><a href="">Chức năng</a></th>
				  </tr>
                 <%
                     double tongtien=0;
                     
                     List<ASPNETMVCApplication.Areas.Supp.ViewModels.CartViewModels> listCartItem = (List<ASPNETMVCApplication.Areas.Supp.ViewModels.CartViewModels>)Session["CartView"]; %>
        
        <% foreach (ASPNETMVCApplication.Areas.Supp.ViewModels.CartViewModels cartItem in listCartItem)
           {
               %><tr>
                    <td><%: cartItem._supplier.CompanyName %></td>

                   <td><% foreach (ASPNETMVCApplication.ActionServiceReference.Product ghe in cartItem._ghemua)
                                                               {
                                                                   %>
                                                                   Ghe so : <%: ghe.ChairNumber %>
                                                                   <% 
                                                                tongtien+=ghe.UnitPrice;
                                                               }
                                                                    %>
                  </td>
                  <td><%: cartItem._ghemua[0].UnitPrice %></td>
                  <td><%: cartItem._ghemua.Count %></td>
                  <td><%: tongtien %></td>
                  <td><button>Xóa</button></td>
                  </tr>
                  <% 
           }
                %>
         
				
			</table>
			<!--  end paging................ -->
			 <div>
               <a class="details" href="../../Shop/Shop/CheckOutOrder">Thanh Toán</a>
             </div>
			<div class="clear"></div>
		 
		</div>
		<!--  end content-table-inner ............................................END  -->
		</td>
		<td id="tbl-border-right"></td>
	</tr>
	<tr>
		<th class="sized bottomleft"></th>
		<td id="tbl-border-bottom">&nbsp;</td>
		<th class="sized bottomright"></th>
	</tr>
	</table>

 

</asp:Content>
